import time
from public.action import *
from public.business import *
from public.testData import *
from public.tools import *

testcase = "dbshop016-删除侧边显示"
firefox = openBrowser(urlAdmin)
DBshopLoginAdmin(firefox)

# 1.点击“添加侧边设置”按钮，
DBshopEnterMenu3(firefox,"商品管理","管理分类","前台侧边设置")

# 轴定位
firefox.find_element_by_xpath('//td[contains(.,"%s")]/following-sibling::td[3]/a[2]'%(frontsideName)).click()

firefox.switch_to.alert.accept()
time.sleep(5)
try:
    firefox.find_element_by_xpath('//td[contains(.,"%s")]' % (frontsideName)).is_displayed()
    writeLog("%s 测试失败"%testcase)
    getPhoto(firefox)
except:
    writeLog("%s 测试通过" % testcase)
# firefox.quit()